def find_positive_integers(string):
    integers = []
    current_integer = ""
    for char in string:
        if char.isdigit():
            current_integer += char
        elif current_integer:
            integers.append(current_integer)
            current_integer = ""
    i=0
    while i< len(integers):
        print(integers[i])
        i+=1
    return 0


input_string = input()
find_positive_integers(input_string)
